package com.yangyouqi.imgdemo.service.impl;

import com.yangyouqi.imgdemo.domain.imgTest;
import com.yangyouqi.imgdemo.repository.ImgTestReposrtory;
import com.yangyouqi.imgdemo.service.imgService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author 杨友奇
 * @Time 2018/7/27
 */
@Service
public class imgServiceImpl implements imgService {
    @Autowired
    private ImgTestReposrtory reposrtory;

    @Override
    public imgTest add(imgTest imgTest,String path) {
        imgTest.setUrl(path);
        return reposrtory.save(imgTest);
    }
}
